/*
 *  This file is part of "SchoolChoice",
 *  a school registration system.
 *
 *  Copyright (C) 2009 Nicolas Decerf, Olivier Jacquemin.
 *
 *  "SchoolChoice" is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 3 of the License, or
 *  (at your option) any later version.
 *
 *  "SchoolChoice" is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program: see the file COPYING.txt.  If not, see
 *  http://www.gnu.org/licenses/.
 */

package be.schoolchoice.webapp.data;

import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

public class UserProfile {
    @PrimaryKey
    @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
	private String id = "";
	
    @Persistent
    private String alias = "";

	public void setNrn(String nrn) {
		this.nrn = nrn;
	}

	public void setPwd(String pwd) {
		this.pwd = pwd;
	}

	@Persistent
    private String nrn = "";

    @Persistent
    private String pwd = "";

    @Persistent
    private String firstName = "";

    @Persistent
    private String lastName = "";

    @Persistent
    private String streetAndNumber = "";

    @Persistent
    private String postalCode = "";

    @Persistent
    private String city = "";

    /**
     * Constructor without arguments: mandatory for jabsorb serialization.
     * (Avoids "could not unmarshall" error.)
     */
    public UserProfile() {
    }

    public UserProfile(String alias, String firstName, String lastName,
			String streetAndNumber, String postalCode, String city,
			String nrn, String pwd) {
		super();
		this.alias = alias;
		this.firstName = firstName;
		this.lastName = lastName;
		this.streetAndNumber = streetAndNumber;
		this.postalCode = postalCode;
		this.city = city;
		this.nrn = nrn;
		this.pwd = pwd;
	}

	public String getAlias() {
		return alias;
	}

	public void setAlias(String alias) {
		this.alias = alias;
	}

	public String getFirstName() {
		return firstName;
	}

	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}

	public String getLastName() {
		return lastName;
	}

	public void setLastName(String lastName) {
		this.lastName = lastName;
	}

	public String getStreetAndNumber() {
		return streetAndNumber;
	}

	public void setStreetAndNumber(String streetAndNumber) {
		this.streetAndNumber = streetAndNumber;
	}

	public String getPostalCode() {
		return postalCode;
	}

	public void setPostalCode(String postalCode) {
		this.postalCode = postalCode;
	}

	public String getCity() {
		return city;
	}

	public void setCity(String city) {
		this.city = city;
	}

    public String getNrn() {
		return nrn;
	}

	public String getPwd() {
		return pwd;
	}
}
